﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace AutoCompleteListBuilder
{
    public partial class TestHarness : UserControl
    {
        List<LstItm> lookupItems;
        public TestHarness()
        {
            InitializeComponent();
            
            lookupItems = new List<LstItm>();

            createLookupItems(lookupItems);

            this.AutoListBuilder1._autocompletebox.ItemsSource = lookupItems;


        
        
        
        }

        public void createLookupItems(List<LstItm> lookupItems)
        {
            string[] Stuff = {"New York","New Haven", "New Brumsfield", "Cat", "Dog", "Mouse", "BMW", "Ford" };
            string creator = "Bill";
            DateTime dtg = DateTime.Now;

            LstItm i;
            foreach (string item in Stuff)
            {
                i = new LstItm();
                i.description = item;
                i.guid = Guid.NewGuid();
                i.createdBy = creator;
                i.createdON = dtg;
                lookupItems.Add(i);
            }
        }
    }

    

}
